<!DOCTYPE html>
<html lang="zh-cn" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>添加订单信息</title>
    <link rel="stylesheet" href="../../static/layui/css/layui.css">
    <link rel="stylesheet" href="../../static/css/style.css">
    <style>
        .layui-form-pane .layui-form-label{
            width: 125px;
        }
    </style>
</head>
<body>
    <div id="main">
        <!--<div class="title">-->
            <!--&lt;!&ndash;<h3 style="font-weight: bold;">添加订单</h3>&ndash;&gt;-->
            <!--<hr class="layui-bg-green">-->
        <!--</div>-->
        <form class="layui-form layui-form-pane m-form">
            <fieldset class="layui-elem-field layui-field-title" style="width: 99%;">
                <legend style="font-size: 16px;">寄件人信息</legend>
            </fieldset>
            <div class="layui-form-item">
                <input type="hidden" name="id" th:value="${order.getId()}">
                <div class="layui-inline">
                    <label class="layui-form-label">真实姓名<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getSendername()}" type="text" name="sendername" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
                <div class="layui-inline">
                    <label class="layui-form-label">联系电话<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getSenderphone()}" type="text" name="senderphone" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">寄件地址</label>
                <div class="layui-input-inline">
                    <select name="spro" id="spro" lay-verify="required" lay-search lay-filter="spro">
                        <option th:value="${s[0]}" th:text="${s[0]}" value="">请选择省</option>
                        <!--<option th:if="${s[0]} eq ${s[1]}" th:value="${s[0]+'市'}" th:text="${s[0]+'市'}" value="">请选择省</option>-->
                        <!--<option th:if="${s[0]} ne ${s[1]} &&" th:value="${s[0]+'省'}" th:text="${s[0]+'省'}" value=""></option>-->
                    </select>
                </div>
                <div class="layui-input-inline" style="margin-left: -11px;">
                    <select name="scity" id="scity" lay-verify="required" lay-search lay-filter="scity">
                        <option th:value="${s[1]}" th:text="${s[1]}" value="">请选择市</option>
                    </select>
                </div>
                <div class="layui-input-inline" style="margin-left: -11px;">
                    <select name="sdis" id="sdis" lay-verify="required" lay-search>
                        <option th:value="${s[2]}" th:text="${s[2]}" value="">请选择县/区</option>
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">取件地址</label>
                <div class="layui-input-inline">
                    <select name="qpro" id="qpro" lay-verify="required" lay-search lay-filter="qpro">
                        <option th:value="${q[0]}" th:text="${q[0]}" value="">请选择省</option>
                        <!--<option th:if="${q[0]} eq ${q[1]}" th:value="${q[0]+'市'}" th:text="${q[0]+'市'}" value="">请选择省</option>-->
                        <!--<option th:if="${q[0]} ne ${q[1]}" th:value="${q[0]+'省'}" th:text="${q[0]+'省'}" value=""></option>-->
                    </select>
                </div>
                <div class="layui-input-inline" style="margin-left: -11px;">
                    <select name="qcity" id="qcity" lay-verify="required" lay-search lay-filter="qcity">
                        <option th:value="${q[1]}" th:text="${q[1]}" value="">请选择市</option>
                    </select>
                </div>
                <div class="layui-input-inline" style="margin-left: -11px;">
                    <select name="qdis" id="qdis" lay-verify="required" lay-search>
                        <option th:value="${q[2]}" th:text="${q[2]}" value="">请选择县/区</option>
                    </select>
                </div>
                <div class="layui-inline">
                    <label class="layui-form-label">详细地址<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getQujianaddrdtl()}" type="text" name="qujianaddrdtl" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
            </div>
            <fieldset class="layui-elem-field layui-field-title" style="width: 99%;">
                <legend style="font-size: 16px;">收件人信息</legend>
            </fieldset>
            <div class="layui-form-item">
                <div class="layui-inline">
                    <label class="layui-form-label">收件人姓名<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getrname()}" type="text" name="rname" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
                <div class="layui-inline">
                    <label class="layui-form-label">收件人电话<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getRephone()}" type="text" name="rephone" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">收件人地址</label>
                <div class="layui-input-inline">
                    <select name="rpro" id="rpro" lay-verify="required" lay-search lay-filter="rpro">
                        <!--<option th:if="${r[0]} eq ${r[1]}" th:value="${r[0]+'市'}" th:text="${r[0]+'市'}" value="">请选择省</option>-->
                        <!--<option th:if="${r[0]} ne ${r[1]}" th:value="${r[0]+'省'}" th:text="${r[0]+'省'}" value=""></option>-->
                        <option th:value="${r[0]}" th:text="${r[0]}" value="">请选择省</option>
                    </select>
                </div>
                <div class="layui-input-inline" style="margin-left: -11px;">
                    <select name="rcity" id="rcity" lay-verify="required" lay-search lay-filter="rcity">
                        <option th:value="${r[1]}" th:text="${r[1]}" value="">请选择市</option>
                    </select>
                </div>
                <div class="layui-input-inline" style="margin-left: -11px;">
                    <select name="rdis" id="rdis" lay-verify="required" lay-search>
                        <option th:value="${r[2]}" th:text="${r[2]}" value="">请选择县/区</option>
                    </select>
                </div>
                <div class="layui-inline">
                    <label class="layui-form-label">详细地址<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getReaddrdtl()}" type="text" name="readdrdtl" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
            </div>
            <fieldset class="layui-elem-field layui-field-title" style="width: 99%;">
                <legend style="font-size: 16px;">物品信息</legend>
            </fieldset>
            <div class="layui-form-item">
                <div class="layui-inline">
                    <label class="layui-form-label">物品名称<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getHwmc()}" type="text" name="hwmc" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
                <div class="layui-inline">
                    <label class="layui-form-label">物品重量(kg)<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getHwzl()}" type="text" name="hwzl" placeholder="请输入" lay-verify="number|required" class="layui-input">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-inline">
                    <label class="layui-form-label">订单类别<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:checked="${order.getOrderclass()=='普通'?'checked':'false'}" type="radio" name="orderclass" value="普通" title="普通" lay-verify="required" checked class="layui-input">
                        <input th:checked="${order.getOrderclass()=='加急'?'checked':'false'}" type="radio" name="orderclass" value="加急" title="加急" lay-verify="required" class="layui-input">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-inline">
                    <label class="layui-form-label">注意事项<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getAttention()}" type="text" name="attention" placeholder="请输入" lay-verify="required" class="layui-input">
                    </div>
                </div>
                <div class="layui-inline">
                    <label class="layui-form-label">总费用<span style="color: red;">*</span></label>
                    <div class="layui-input-inline">
                        <input th:value="${order.getPrice()}" type="text" name="price" placeholder="请输入" lay-verify="number|required" class="layui-input">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <button class="layui-btn" lay-submit lay-filter="edito">提交</button>
                <button type="reset" class="layui-btn layui-btn-warm" style="margin-left: -4px;">重置</button>
            </div>
        </form>
    </div>
</body>
<script src="../../static/js/jquery-3.4.1.js"></script>
<script src="../../static/layui/layui.js"></script>
<script src="../../static/js/order/style.js"></script>
<script src="../../static/js/order/address.js"></script>
</html>